package com.example.javaeekeshe.service.impl;

import com.example.javaeekeshe.mapper.AdMapper;
import com.example.javaeekeshe.pojo.AdBean;
import com.example.javaeekeshe.service.IAdService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class AdService implements IAdService {

    @Autowired
    AdMapper adMapper;

    @Override
    public List<AdBean> selectAllAd() {
        return adMapper.selectAllAd();
    }

    @Override
    public void addAd(AdBean adBean) {
        adMapper.addAd(adBean);
    }

    @Override
    public void del(Integer id) {
        adMapper.del(id);
    }

    @Override
    public void update(AdBean adBean) {
        adMapper.update(adBean);
    }
}
